//
//  MZY_informationCell.m
//  FullHouse
//
//  Created by dllo on 16/1/22.
//  Copyright © 2016年 yy. All rights reserved.
//

#import "MZY_informationCell.h"

#define WIDTH self.contentView.frame.size.width
#define HEIGHT self.contentView.frame.size.height

@implementation MZY_informationCell

- (void)dealloc
{
    [self.faceImageView release];
    [self.nickLabel release];
    [self.rightImageView release];
    [super dealloc];
}

- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self createView];
    }
    return self;
}

- (void)createView{
    
    self.contentView.backgroundColor = [UIColor orangeColor];
    
    self.faceImageView = [[UIImageView alloc] init];
    [self.contentView addSubview:self.faceImageView];
    [self.faceImageView release];
    
    self.nickLabel = [[UILabel alloc]init];
    [self.contentView addSubview:self.nickLabel];
    [self.nickLabel release];
    
    self.rightImageView = [[UIImageView alloc]init];
    [self.contentView addSubview:self.rightImageView];
    [self.rightImageView release];
}

- (void)layoutSubviews{
    [super layoutSubviews];
    self.faceImageView.frame = CGRectMake(10, 10, HEIGHT - 20, HEIGHT - 20);
    self.nickLabel.frame = CGRectMake(HEIGHT, HEIGHT / 2 - 10, 100, 20);
    self.rightImageView.frame = CGRectMake(WIDTH - 40, 30, 30, HEIGHT - 60);
}

@end
